Skip to main content
Version: legacy

Location Message

Location request messages contain body text and a Send location button that users can tap. Tapping the button displays a location sharing screen which the user can then use to share their location.

To send a location request message, first assemble an interactive object with text you wish to display in the message:

Alt text

Parameters:

PropertyDescription
typeSet to location_request_message.
body typeSet to text.
body textSet to the text you want to display above the 'Send location' button.
action.nameSet to send_location.

Payload

{
"messages": [
{
"sender": "9180109XXXXX",
"to": "91xxxxxxxxxx",
"messageId": "",
"transactionId": "",
"channel": "wa",
"type": "interactive",
"interactive": {
"type": "location_request_message",
"body": {
"type": "text",
"text": "Let's start with your 📍 pickup. You can either manually enter an address or share your location."
},
"action": {
"name": "send_location"
}
}
}
],
"responseType": "json"
}